<?php

/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/


Route::get('/', function () {
    return view('welcome');
});


Route::get('/login','LoginController@login');               //登陆页面

Route::get('/register','LoginController@register');         //注册页面
Route::post('/student', 'StudentController@createStudent'); //创建学生

Route::post('/login','LoginController@signin');              //登录


Route::get('/admin/login','AdminController@login');          //管理员登录页
Route::get('/admin','AdminController@admin');           //管理员页面
Route::post('/admin','AdminController@signin');  

Route::get('/admin/teacher','AdminController@teacher');   
Route::get('/admin/student','AdminController@student');   
Route::get('/admin/salecost','AdminController@salecost');   
Route::get('/admin/inventory','AdminController@inventory');   

Route::get('/logout','LoginController@logout');  